#ifndef _SPHERE
#define _SPHERE

#include "base.h"
#include "vector.h"
#include "ray.h"

typedef struct
{
  vector  p; // position
  fNumber r; // radius
} sphere;

void    sphereClear       (sphere *s);
void    sphereCopy        (sphere *dst, sphere *src);
fNumber sphereIntersectRay(sphere *s, ray *r);

#endif // _SPHERE
